<template>
  <BasicModal :show="show" title="放弃" width="30%" :widthComfirm="true" @closeModal="show = false" @comfirm="comfirm">
    <template #content>
      <CommonForm :formList="formList" ref="formRef"></CommonForm>
    </template>
  </BasicModal>
</template>

<script setup lang='ts'>
import { ref } from "vue"
import BasicModal from "@/views/ApplicationDetails/Modals/BasicModal.vue";
import type { IndexFormItem } from "@/views/ApplicationDetails/application-type.ts";
import CommonForm from "@/views/applicationDetails/CommonForm.vue";
const props = defineProps(['process']);
console.log(props.process)
const show = ref<boolean>(false);
const formList = ref<IndexFormItem>([
  { label: "淘汰原因", name: "remark", value: "", component: 'textarea', required: false },
])

const formRef = ref<any>(null)
const comfirm = async () => {
  const res = await formRef.value.submitForm();
  if (!res) return;
  console.log(props.process)
  // formRef.value.resetFields();

}
defineExpose({ show })
</script>

<style lang="less" scoped>
.progress {
  display: flex;
  justify-content: end;
  margin: 24px 0;
  padding-top: 24px;
  ;
  font-weight: 400;
  font-size: 14px;
  color: #333333;

  .desc {

    font-weight: 400;
    font-size: 14px;
    color: #209EE4;

  }
}
</style>
